using System;
using System.Collections.Generic;
using System.Reflection;
using System.Runtime.InteropServices;

using ILRuntime.CLR.TypeSystem;
using ILRuntime.CLR.Method;
using ILRuntime.Runtime.Enviorment;
using ILRuntime.Runtime.Intepreter;
using ILRuntime.Runtime.Stack;
using ILRuntime.Reflection;
using ILRuntime.CLR.Utils;
using System.Linq;

namespace ILRuntime.Runtime.Generated
{
    unsafe class huqiang_Communication_KcpFileCmd_Binding
    {
        public static void Register(ILRuntime.Runtime.Enviorment.AppDomain app)
        {
            BindingFlags flag = BindingFlags.Public | BindingFlags.Instance | BindingFlags.Static | BindingFlags.DeclaredOnly;
            MethodBase method;
            FieldInfo field;
            Type[] args;
            Type type = typeof(huqiang.Communication.KcpFileCmd);

            field = type.GetField("GetFileInfo", flag);
            app.RegisterCLRFieldGetter(field, get_GetFileInfo_0);
            app.RegisterCLRFieldBinding(field, CopyToStack_GetFileInfo_0, null);
            field = type.GetField("ResponesFileInfo", flag);
            app.RegisterCLRFieldGetter(field, get_ResponesFileInfo_1);
            app.RegisterCLRFieldBinding(field, CopyToStack_ResponesFileInfo_1, null);
            field = type.GetField("Download", flag);
            app.RegisterCLRFieldGetter(field, get_Download_2);
            app.RegisterCLRFieldBinding(field, CopyToStack_Download_2, null);
            field = type.GetField("ResponesDownload", flag);
            app.RegisterCLRFieldGetter(field, get_ResponesDownload_3);
            app.RegisterCLRFieldBinding(field, CopyToStack_ResponesDownload_3, null);
            field = type.GetField("ReadyDownload", flag);
            app.RegisterCLRFieldGetter(field, get_ReadyDownload_4);
            app.RegisterCLRFieldBinding(field, CopyToStack_ReadyDownload_4, null);
            field = type.GetField("Upload", flag);
            app.RegisterCLRFieldGetter(field, get_Upload_5);
            app.RegisterCLRFieldBinding(field, CopyToStack_Upload_5, null);
            field = type.GetField("RequestPart", flag);
            app.RegisterCLRFieldGetter(field, get_RequestPart_6);
            app.RegisterCLRFieldBinding(field, CopyToStack_RequestPart_6, null);
            field = type.GetField("SendPart", flag);
            app.RegisterCLRFieldGetter(field, get_SendPart_7);
            app.RegisterCLRFieldBinding(field, CopyToStack_SendPart_7, null);
            field = type.GetField("RecvPart", flag);
            app.RegisterCLRFieldGetter(field, get_RecvPart_8);
            app.RegisterCLRFieldBinding(field, CopyToStack_RecvPart_8, null);
            field = type.GetField("SendCompelete", flag);
            app.RegisterCLRFieldGetter(field, get_SendCompelete_9);
            app.RegisterCLRFieldBinding(field, CopyToStack_SendCompelete_9, null);
            field = type.GetField("RecvCompelete", flag);
            app.RegisterCLRFieldGetter(field, get_RecvCompelete_10);
            app.RegisterCLRFieldBinding(field, CopyToStack_RecvCompelete_10, null);


            app.RegisterCLRCreateDefaultInstance(type, () => new huqiang.Communication.KcpFileCmd());
            app.RegisterCLRCreateArrayInstance(type, s => new huqiang.Communication.KcpFileCmd[s]);

            args = new Type[]{};
            method = type.GetConstructor(flag, null, args, null);
            app.RegisterCLRMethodRedirection(method, Ctor_0);

        }



        static object get_GetFileInfo_0(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.GetFileInfo;
        }

        static StackObject* CopyToStack_GetFileInfo_0(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.GetFileInfo;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_ResponesFileInfo_1(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.ResponesFileInfo;
        }

        static StackObject* CopyToStack_ResponesFileInfo_1(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.ResponesFileInfo;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_Download_2(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.Download;
        }

        static StackObject* CopyToStack_Download_2(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.Download;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_ResponesDownload_3(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.ResponesDownload;
        }

        static StackObject* CopyToStack_ResponesDownload_3(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.ResponesDownload;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_ReadyDownload_4(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.ReadyDownload;
        }

        static StackObject* CopyToStack_ReadyDownload_4(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.ReadyDownload;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_Upload_5(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.Upload;
        }

        static StackObject* CopyToStack_Upload_5(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.Upload;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_RequestPart_6(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.RequestPart;
        }

        static StackObject* CopyToStack_RequestPart_6(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.RequestPart;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_SendPart_7(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.SendPart;
        }

        static StackObject* CopyToStack_SendPart_7(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.SendPart;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_RecvPart_8(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.RecvPart;
        }

        static StackObject* CopyToStack_RecvPart_8(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.RecvPart;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_SendCompelete_9(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.SendCompelete;
        }

        static StackObject* CopyToStack_SendCompelete_9(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.SendCompelete;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }

        static object get_RecvCompelete_10(ref object o)
        {
            return huqiang.Communication.KcpFileCmd.RecvCompelete;
        }

        static StackObject* CopyToStack_RecvCompelete_10(ref object o, ILIntepreter __intp, StackObject* __ret, IList<object> __mStack)
        {
            var result_of_this_method = huqiang.Communication.KcpFileCmd.RecvCompelete;
            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value = result_of_this_method;
            return __ret + 1;
        }



        static StackObject* Ctor_0(ILIntepreter __intp, StackObject* __esp, IList<object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject* __ret = ILIntepreter.Minus(__esp, 0);

            var result_of_this_method = new huqiang.Communication.KcpFileCmd();

            return ILIntepreter.PushObject(__ret, __mStack, result_of_this_method);
        }


    }
}
